<?php
/**
 * 系统默认的 404 页面
 */
namespace app\admin\controller;

class Error extends \think\Controller
{
    public function index()
    {
        $this->city();
        return $this->fetch('common/empty');
    }

    public function _empty($name)
    {
        
        $this->city();
        return $this->fetch('common/empty');
    }

    //注意 city方法 本身是 protected 方法
    protected function city()
    {
        //根据当前控制器名来判断要执行那个城市的操作
        $empty['c'] = \Request::controller();
        $empty['a'] = \Request::action();

        $this->assign([
            'e' => $empty,
        ]);
    }
}
